<?php
// +----------------------------------------------------------------------
// | 企业注册
// +----------------------------------------------------------------------
namespace app\user\controller;

use dc\controller\AdminBaseController;
use dragon\Company\Entity\Company;
use dragon\SysConfig;
use think\Db;

class CompanyController extends AdminBaseController
{
    public function _initialize()
    {
    }

    /**
     * 企业申请
     */
    public function apply()
    {
        $this->assign('company_types', Db::name('company_type')->where(['open' => 1])->select());
        return $this->fetch();
    }

    public function applyPost() {
        $post    = $this->request->post();
        $post['status'] = SysConfig::COMPANY_APPLY;
        $company = Company::create($post);

    }

}